package com.alipay.sofa.award.biz.service.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.LinkedList;
import java.util.List;

/**
 * AwardConfigurationProperties
 *
 * @author yangguanchao
 * @since 2018/09/08
 */
@Component
@ConfigurationProperties(prefix = "com.alipay.sofa.award")
public class AwardConfigurationProperties {

    /***
     * qps 100
     */
    private long   qpsLimitCount   = 1000;

    /***
     * period
     */
    private long   qpsPeriodMills  = 1000;

    private String appId           = "";

    private String appPrivateKey   = "";

    private String alipayPublicKey = "";

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getAppPrivateKey() {
        return appPrivateKey;
    }

    public void setAppPrivateKey(String appPrivateKey) {
        this.appPrivateKey = appPrivateKey;
    }

    public String getAlipayPublicKey() {
        return alipayPublicKey;
    }

    public void setAlipayPublicKey(String alipayPublicKey) {
        this.alipayPublicKey = alipayPublicKey;
    }

    /***
     * list limited uri path
     */
    private List<String> qpsLimitedUriPahList = new LinkedList<String>();

    public long getQpsLimitCount() {
        return qpsLimitCount;
    }

    public void setQpsLimitCount(long qpsLimitCount) {
        this.qpsLimitCount = qpsLimitCount;
    }

    public long getQpsPeriodMills() {
        return qpsPeriodMills;
    }

    public void setQpsPeriodMills(long qpsPeriodMills) {
        this.qpsPeriodMills = qpsPeriodMills;
    }

    public List<String> getQpsLimitedUriPahList() {
        return qpsLimitedUriPahList;
    }

    public void setQpsLimitedUriPahList(List<String> qpsLimitedUriPahList) {
        this.qpsLimitedUriPahList = qpsLimitedUriPahList;
    }
}
